#pragma once
#include "stdafx.h"
//-------------------------------------------------------------------------------------------------
//ProcParamDefInt.h  - Integer Parameter Definition for Image Processing Steps           
//-------------------------------------------------------------------------------------------------

#ifdef PLUGINICPROCSTEPS_EXPORTS
#define PLUGINICPROCSTEPS_API __declspec(dllexport)
#else
#define PLUGINICPROCSTEPS_API __declspec(dllimport)
#endif
#include "IPluginICProcStepsParamDefInt.h"
#include "procparamdef.h"

class PLUGINICPROCSTEPS_API ProcParamDefInt  : public ProcParamDef, IPluginICProcStepsParamDefInt
{
friend class ImageProcFn;
public:
	ProcParamDefInt(void);
	ProcParamDefInt::ProcParamDefInt(int index, const char *Name, const char *Description, IPluginICProcStepsParamDef::Direction Dir, int MinVal, int MaxVal);
	virtual ~ProcParamDefInt(void);

				//IMxPluginBase
	virtual long		MXSTDMETHOD DestroyPtr(void);
	virtual long		MXSTDMETHOD DuplicatePtr(void);
	virtual void *		MXSTDMETHOD Dynamic_cast(const char *IId);
	virtual const char *MXSTDMETHOD GetInterfaceGUID(void)  { return IPluginICProcStepsParamDefIntIID::GUID(); }
	virtual const char *MXSTDMETHOD GetInterfaceName(void) { return IPluginICProcStepsParamDefIntIID::Name(); }
				//IPluginICProcStepsParamDef
	virtual int			MXSTDMETHOD GetIndex() { return ProcParamDef::GetIndex(); }
	virtual const char *MXSTDMETHOD GetName() { return ProcParamDef::GetName(); }
	virtual const char *MXSTDMETHOD GetDescription() { return ProcParamDef::GetDescription(); }
	virtual IPluginICProcStepsParamDef::Direction MXSTDMETHOD GetDirection()  { return ProcParamDef::GetDirection(); }
	virtual bool		MXSTDMETHOD IsValid()  { return ProcParamDef::IsValid(); }
	virtual	bool		MXSTDMETHOD IsMatch (IPluginICProcStepsParam  *param, IPluginICProcStepsParamDef::Direction dir);
	virtual IPluginICProcStepsParamDef::TypeP MXSTDMETHOD GetTypeP() { return IPluginICProcStepsParamDef::intP; }
	virtual const char *MXSTDMETHOD GetTypeStr() { return IPluginICProcStepsParamDefIntP; }
	virtual const char *MXSTDMETHOD GetDefaultValueStr();
	virtual const char *MXSTDMETHOD GetString();
				//IPluginICProcStepsParamDefInt
	virtual int			MXSTDMETHOD GetMaxValue() { return _MaxVal; }
	virtual int			MXSTDMETHOD GetMinValue() { return _MinVal; }

protected:		//ProcParamDef
	virtual		bool	SetXml(void *xmlParam);
	virtual		bool	Validate();

private:
	int	_MinVal;
	int _MaxVal;
};


//-------------------------------------------------------------------------------------------------
//			E N D   O F   F I L E
//-------------------------------------------------------------------------------------------------